
<!DOCTYPE html>

<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<body>
获取model里面的内容：<span th:text="${msg}"></span>
<br/>
获取session里面的内容：<span th:text="${#session.getAttribute('sessionMsg')}"></span>
</body>
</html>